package com.lhl.booksystem.util;

import lombok.Data;

import java.io.Serializable;

/**
 * @author LHL
 */
@Data
public class R<T> implements Serializable {
 private Integer code;
 private String message;
 private boolean flag;

 private T data;

    public R() {
    }

    public R(Integer code, String message, boolean flag) {
        this.code = code;
        this.message = message;
        this.flag = flag;
    }

    public R(Integer code, String message, boolean flag, T data) {
        this.code = code;
        this.message = message;
        this.flag = flag;
        this.data = data;
    }
}
